# Maintainer: Alexey Pavlov <alexpux@gmail.com>

pkgname=nasm
pkgver=2.11.08
pkgrel=1
pkgdesc="An 80x86 assembler designed for portability and modularity"
arch=('i686' 'x86_64')
url="http://www.nasm.us"
license=('BSD')
depends=('msys2-runtime')
install=nasm.install
source=("http://www.nasm.us/pub/nasm/releasebuilds/${pkgver}/${pkgname}-${pkgver}.tar.xz")
sha1sums=('6908296ac437b3ade79fadfaad0efcfd99582f70')

build() {
  cd ${pkgname}-${pkgver}
  ./configure --prefix=/usr
  make all -j1
  make -C doc info
}

package() {
  cd ${pkgname}-${pkgver}
  make INSTALLROOT="${pkgdir}" install install_rdf
  install -dm755 "${pkgdir}"/usr/share/info
  install -m644 doc/info/* "${pkgdir}"/usr/share/info/
  install -D -m644 LICENSE "${pkgdir}"/usr/share/licenses/nasm/LICENSE
}
